import { axiosInstance } from './config';

// 需求1：请求轮播图数据
export const getBannerRequest = () => {
    return axiosInstance.get('/banner');
};

// 需求2：请求推荐歌单数据
export const getRecommendListRequest = () => {
    return axiosInstance.get('/personalized');
};

// 需求3：获取热门歌手列表
export const getHotSingerListRequest = (count) => {
    return axiosInstance.get(`/top/artists?offset=${count}`);
};

// 需求4： 请求歌手列表
export const getSingerListRequest = (type='-1', area='-1', alpha ,count) => {
    return axiosInstance.get(`/artist/list?type=${type}&area=${area}&initial=${alpha.toLowerCase()}&offset=${count}`);
};

// 需求5： 获取排行榜
export const getRankListRequest = () => {
    return axiosInstance.get('/toplist/detail');
};

// 需求6： 获取歌单详细数据
export const getAlbumDetailRequest = id => {
    return axiosInstance.get(`/playlist/detail?id=${id}`);
};

// 需求7：获取歌手详情
export const getSingerInfoRequest = id => {
    return axiosInstance.get(`/artist/detail?id=${id}`);
};

// 需求8: 获取歌手热门歌曲
export const getSingerHotSongsRequest = id => {
    return axiosInstance.get(`/artist/top/song?id=${id}`);
};